<template>
  <div>
    <div class="title">周末去哪儿</div>
    <ul class="item">
      <li class="border-bottom" v-for="item of weekendData" :key="item.id">
        <div class="item-img-box">
          <img class="item-img" :src="item.url" />
        </div>
        <div class="item-info">
          <p class="item-title">{{item.title}}</p>
          <p class="item-desc">{{item.desc}}</p>
        </div>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: 'HomeWeekend',
  props: {
    weekendData: Array
  },
  data: function () {
    return {
    }
  }
}
</script>

<style lang="stylus" scoped>
  @import "~styles/varibles.styl"
  .title
    width:100%
    height: 0.8rem
    background: #eee
    font-size: 0.3rem
    text-indent: 0.2rem
    line-height: 0.8rem
  .item
    width: 100%
    background: #eee
  .item li
    width:100%
    height: 4rem
    margin-bottom: .1rem
    background: #fff
    .item-img-box
      overflow:hidden
      width:100%
      height:0
      padding-bottom: 37%
      .item-img
        width:100%
    .item-info
      .item-title
        font-size: .3rem
        margin: .2rem  0rem  .15rem  .2rem
        color: #212121
        ellipsi()
      .item-desc
        font-size: .18rem
        margin-left: .2rem
        color: #212121
        ellipsi()
</style>
